<?php
Abstract Class page_Base {
    protected $registry;
    var $args = array();                // arguments from request url
    var $tp;                                       // global template
    var $access_min = 0;            // min required access level
    var $access_max = 100;      // max req access level (reserved)
    var $path;

    public function __construct($registry,$args) {
        $this->registry = $registry;
        $this->tp = $this->registry->get('template');
        $this->args = $args;
    }
    
    public function isAllowed() {
        $user = $this->registry->get('user');
        $uAcc = $user->getAccess();
        if(($uAcc <= $this->access_max) && ($uAcc >= $this->access_min)) {
            return TRUE;
        }
        else {
            return FALSE;
        }
    }

    abstract function index();
    abstract function getSettings();

}

?>